package com.woniu.owner.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.woniu.common.ResponseData;
import com.woniu.owner.entity.SmartUnlocking;
import com.woniu.owner.service.SmartUnlockingService;
import com.woniu.owner.mapper.SmartUnlockingMapper;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author admin
 * @description 针对表【smart_unlocking】的数据库操作Service实现
 * @createDate 2025-01-09 13:01:10
 */
@Service
public class SmartUnlockingServiceImpl extends ServiceImpl<SmartUnlockingMapper, SmartUnlocking>
        implements SmartUnlockingService {

    @Override
    public ResponseData<?> unlock(SmartUnlocking smartUnlocking) {
        save(smartUnlocking);
        return new ResponseData<>().ok();
    }

    @Override
    public ResponseData<?> queryAllSmartUnlocking() {
        List<SmartUnlocking> smartUnlockings = lambdaQuery().list();
        return new ResponseData<>().ok(smartUnlockings);
    }
}




